<template>
	<view class="home">
		<view class="abrall">
			<view class="abratite">
				<view class="text">
					流速仪名称：
				</view>
				<view class="input">
					{{liusiyiitem.name}}
				</view>
			</view>
			<view class="abranub">
				<view class="text">
					a系数：
				</view>
				<view class="input">
					{{liusiyiitem.aa}}
				</view>
			</view>
			<!-- 			<view class="fanwei">
				a系数范围：0.0-6.0
			</view> -->
			<view class="abranub">
				<view class="text">
					b系数：
				</view>
				<view class="input">
					{{liusiyiitem.bb}}
				</view>
			</view>
			<!-- 			<view class="fanwei">
				b系数范围：0.0-6.0
			</view> -->
			<view class="abranub">
				<view class="text">
					c系数：
				</view>
				<view class="input">
					{{liusiyiitem.cc}}
				</view>
			</view>
			<!-- 			<view class="fanwei">
				c系数范围：1-100
			</view> -->
		</view>
		<!-- 流速仪公式 -->
		<view class="formula">
			<view class="formulatop">
				流速公式：V=a+bn，n=N*C/T
			</view>
			<view class="formulabom">
				<view class="formulaitem">
					C：转数比
				</view>
				<view class="formulaitem">
					n：转数
				</view>
				<view class="formulaitem">
					N：信号数
				</view>
				<view class="formulaitem">
					T：信号时长
				</view>
			</view>
		</view>
		<!-- 		<view class="" style="padding: 50rpx;" @click="saveCezhan">
			<u-button type="primary" shape="circle" text="保存流速仪"></u-button>
		</view> -->
	</view>
</template>

<script>
	export default {
		data() {
			return {
				placeholderStyle: "color:#c1c1c1;font-size:14px",
				styles: {
					color: '#999999',
					borderColor: '#c3c3c3'
				},
				liusiyiitem: {},
				cezhanId: null
			}
		},
		onLoad(option) {
			console.log('option', option);
			this.cezhanId = option.id
			this.cezhanlist = this.vuex_liusuyiList
		},
		onShow() {
			console.log('打印', this.cezhanId);
			let cezhanArr = this.cezhanlist
			let cezhanObj = {}
			for (let i in cezhanArr) {
				console.log('i', i);
				if (cezhanArr[i].id == this.cezhanId) {
					cezhanObj = cezhanArr[i]
				}
			}
			this.liusiyiitem = cezhanObj
			console.log('cezhanObj', cezhanObj);
		},
		destroyed() {
			console.log('销毁');
		},
		methods: {

		}
	}
</script>
<style>
	page {
		background-color: #f8f8f8;
	}
</style>
<style scoped lang="scss">
	.hometop {
		display: flex;
		align-items: center;
		justify-content: center;
		font-size: 35rpx;
		font-weight: bold;
		text-align: center;
		color: #43b998;
		padding: 10rpx 0 0 0;
		border-radius: 10rpx;
	}

	.abr {
		display: flex;
		justify-content: space-between;
		padding: 30rpx;

		.abr-l {
			width: 690rpx;
			background-color: #ffffff;
			border-radius: 10rpx;
			display: flex;
			flex-wrap: wrap;
			justify-content: space-around;

			.abritem {
				display: flex;
				align-items: center;
				justify-content: space-between;
				padding: 20rpx;

				.abrtext {
					// width: 200rpx;
					font-size: 35rpx;
					background-color: #327983;
				}
			}
		}
	}

	.bott {
		text-align: center;
	}

	.xishu {
		color: #f14321;
		font-size: 25rpx;
	}

	//流速仪
	.abrall {
		width: 590rpx;
		padding: 50rpx;
		margin: 20rpx 30rpx;
		border-radius: 30rpx;
		background-color: #fff;
		box-shadow: 0rpx 5rpx 20rpx #bfbfbf;

		.abratite {
			display: flex;
			align-items: center;
			justify-content: space-between;
			margin: 30rpx 0;
			font-size: 40rpx;
			color: #67938f;

			.text {
				width: 260rpx;
				display: inline-block;
				text-align-last: justify;
				// background-color: #ffaa7f;
			}

			.input {
				width: 320rpx;
				// background-color: #aa55ff;
			}
		}

		.abranub {
			display: flex;
			align-items: center;
			justify-content: space-between;
			margin: 30rpx 0 10rpx 0;
			font-size: 40rpx;
			color: #67938f;

			.text {
				width: 260rpx;
				display: inline-block;
				text-align-last: justify;
				// background-color: #ffaa7f;
			}

			.input {
				width: 320rpx;
				// background-color: #aa55ff;
			}
		}

		.fanwei {
			margin-bottom: 30rpx;
			text-align: center;
		}
	}

	//流速公式
	.formula {
		width: 750rpx;
		margin-top: 40rpx;
		display: flex;
		flex-direction: column;
		align-items: center;

		.formulatop {
			width: 650rpx;
			text-align: center;
			line-height: 80rpx;
			font-size: 40rpx;
			border-radius: 15rpx 15rpx 0 0;
			background-color: #327983;
			color: #ffffff;
		}

		.formulabom {
			width: 650rpx;
			height: 250rpx;
			text-align: center;
			line-height: 70rpx;
			font-size: 30rpx;
			border-radius: 0 0 15rpx 15rpx;
			background-color: #b0ddd4;
			color: #ffffff;
			display: flex;
			flex-wrap: wrap;
			align-content: space-around;
			justify-content: space-around;

			.formulaitem {
				width: 250rpx;
				height: 70rpx;
				margin: 0rpx;
				line-height: 70rpx;
				border-radius: 10rpx;
				background-color: #ffffff;
				color: #327983;
			}
		}
	}
</style>